/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package chapter6;
import java.io.Console;
/**
 *
 * @author Denise Carolina
 */
public class ConsoleTest {

    /**
     * @param args the command line arguments
     */
    public static void main(String[] args) {
        Console c = System.console();
        char[] pwd;
        pwd = c.readPassword("%s", "pwd: ");
        for(char c1: pwd){
            c.format("%c", c1);
        }
        c.format("\n");

        String input = "test";
        while(true){
            input = c.readLine("%s", "input?: ");
            c.format("output: ", input);
        }

    }

    String doStuff(String a){
          return "result:: " + a;
    }
}
